/**
 * Collaborative Story Development Web Application (CSDApp) Copyright Anton
 * Strack 2014
 *
 * This file is part of Collaborative Story Development Application (CSDApp).
 *
 * CSDApp is free software: you can redistribute it and/or modify it under the
 * terms of the GNU General Public License as published by the Free Software
 * Foundation, either version 3 of the License, or any later version.
 *
 * CSDApp is distributed in the hope that it will be useful, but WITHOUT ANY
 * WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR
 * A PARTICULAR PURPOSE. See the GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License along with
 * CSDApp. If not, see <http://www.gnu.org/licenses/>.
 *
 */
package csdwa;

import java.sql.Timestamp;

/**
 * This class represents a relationship type for the application. Primarily it
 * represents the relationship between the post of Column A and the post of
 * Column B in the RelatedMap object.
 *
 * @author Anton Strack
 */
public class Relationship extends Resource implements CsdwaRecordable {

    /**
     * the name of the relationship
     */
    protected String name;
    /**
     * the description of the relationship
     */
    protected String description;

    public Relationship(int resourceTypeId) {
        super(resourceTypeId);
    }

    /**
     * @return the name
     */
    public String getName() {
        return name;
    }

    /**
     * @param name the name to set
     */
    public void setName(String name) {
        this.name = name;
    }

    /**
     * @return the description
     */
    public String getDescription() {
        return description;
    }

    /**
     * @param description the description to set
     */
    public void setDescription(String description) {
        this.description = description;
    }

    @Override
    public int getStateId() {
        return InfoAggregator.getInstance().getStateTypeId("draft");
    }

    @Override
    public Timestamp getUpdatedDate() {
        throw new UnsupportedOperationException("Not supported yet.");
    }

    @Override
    public Timestamp getCreatedDate() {
        throw new UnsupportedOperationException("Not supported yet.");
    }
}
